package com.wx.cloud.user.model;

import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.data.annotation.Id;
import org.springframework.data.elasticsearch.annotations.Document;
import org.springframework.data.elasticsearch.annotations.Field;
import org.springframework.data.elasticsearch.annotations.FieldType;

import java.io.Serializable;

@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Document(indexName = "login_info",shards = 2,replicas = 2)
public class LoginInfo implements Serializable {
    @Id
    private Integer id;
    @Field(analyzer = "ik_max_word",type = FieldType.Text)
    private String userCode;
    private String name;
    private String loginIp;
    private String loginTime;
}
